			$(function(){
				//tooltip
				$(".tooltip").easyTooltip();
		
				// Check all the checkboxes when the head one is selected:
				$('.checkall').live('click', function() {
					$(this).parent().parent().parent().parent().find("input[type='checkbox']").attr('checked', $(this).is(':checked'));   
					});
				// Accordion
				$("#accordion").accordion({ header: "h3" });
	
			});
			
			//公用函数

			function loadMainHtml(purviewUrl){
				if($.trim(purviewUrl)!=""){
					$.get(ctx+purviewUrl,
		                    function(data){
		                       $("#dynamticHtml").empty().append(data);
		                    });
				}
			}
			
			function hideNotifications(){
				$(".message").hide("fast");
			}
			
			function showSuccess(){
				hideNotifications();
				$("div[class='message success']").show("slow");
			}
			
			function showWarning(){
				hideNotifications();
	            $("div[class='message warning']").show("slow");
	        }
			
			function showError(){
				hideNotifications();
	            $("div[class='message error']").show("slow");
	        }
			
			function showInformation(){
				hideNotifications();
	            $("div[class='message information']").show("slow");
	        }
			
			//跨框架显示消息
			function hideNotifications(documentObject){
				$(".message",documentObject).hide("fast");
			}
			
			function showSuccess(documentObject){
	            hideNotifications(documentObject);
	            $("div[class='message success']",documentObject).show("normal");
	        }
	        
	        function showWarning(documentObject){
	            hideNotifications(documentObject);
	            $("div[class='message warning']",documentObject).show("normal");
	        }
	        
	        function showError(documentObject){
	            hideNotifications(documentObject);
	            $("div[class='message error']",documentObject).show("normal");
	        }
	        
	        function showInformation(documentObject){
	            hideNotifications(documentObject);
	            $("div[class='message information']",documentObject).show("normal");
	        }
